<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>YC论坛-博文详细</title>
<meta http-equiv="X-UA-Compatiable" content="IE=edge">
<link type="image/icon" rel="shortcut icon" href="images/yc.png"/>
<meta name="viewport" content="width=device-width,initial-scale=1">
<link rel="stylesheet" type="text/css" href="css/bootstrap.css">
<link rel="stylesheet" type="text/css" href="css/banse.css">
</head>
<body>
	<nav class="navbar navbar-default navbar-fixed-top" role="navigation">
		<div class="container">
			<div class="navbar-header"> 
	            <a class="navbar-brand fontLogo" href="#"><img src="images/logo.png" height="50px"/></a>
	        </div>
	        <ul class="nav navbar-nav navbar-left">
	        	<li><a href="#">首页</a></li>
	        	<li><a href="#">动态</a></li>
	        	<li><a href="#">收藏</a></li>
	        </ul>
	        <form action="" class="navbar-form navbar-left">
	        	<div class="form-group">
	        		<input type="text" class="form-control" placeholder="Search">
	        		<button type="submit" class="btn btn-default">搜索</button>
	        	</div>
	        </form>
	        <ul class="nav navbar-nav navbar-right">
	        	<li><a href="#"><img src="images/user.png" id="userLoginPhoto" class="userP" /></a></li>
				<li><a href="#" id="currentloginUser">&nbsp;登录</a></li>
	        	<li id="addBlog"></li>
				<li><a href="#">注册</a></li>
	        </ul>
		</div>
	</nav>
	
	<div class="container main" id="index_blog_content">
		
			
				
	</div>
</body>
<script type="text/javascript" src="js/jquery-3.4.1.min.js"></script>
<script type="text/javascript" src="js/bootstrap.js"></script>
<script type="text/javascript">
  var bid=location.search.replace("?","");
  if(bid==""){
	  location.href="index.html";
  }
  $(function(){
	  $.post("blog",{op:"findByBid",bid:bid}, result=>{
		  var str='<div class="row"><div class="col-md-12 col-sm-12 col-xs-12">';
			str +='<div class="panel panel-success"><div class="panel-heading"><h4>';
			str +='<a href="detail.html?'+result.bid+'" target="_blank" >['+ result.tname +']'+ result.title +  '</a></h4></div>';
			str +='<div class="panel-body"><div class="content_a"><h5 class="C_">';
			str +=result.content + '</h5></div></div><div class="btnAll"><ul class="nav nav_a">';
			str +='<li><span class="badge badge_a">'+ result.nickName+'</span></li>';
			str +='<li><span class="badge badge_a">'+ result.bdate +'</span></li>';
            str +='<li><a href=""><span class="badge badge_a">'+ result.collect +'</span>&nbsp;收藏</a></li>';
            str +='<li><a href=""><span class="badge badge_a">'+ result.support +'</span>&nbsp;推荐</a></li>';
            str +='<li><a href=""><span class="badge badge_b">'+ result.oppose +'</span>&nbsp;反对</a></li></ul></div></div></div></div>';
		 $("#index_blog_content").append($(str));
	  },"json");
  })
</script>
</html>